package main

import (
	"fmt"
	"strconv"
)

/*
	string --> basic type
		ParseInt(s string, base int, bitSize int) (i int64, err error)
		ParseBool(str string) (value bool, err error)
		ParseFloat(s string, bitSize int) (f float64, err error)
		ParseUint(s string, base int, bitSize int) (n uint64, err error)

*/
func main() {
	var s1 string = "t"
	var s2 string = "-12"
	var s3 string = "12.99"
	var s4 string = "123"

	var b bool
	b, _ = strconv.ParseBool(s1)
	fmt.Println(b)

	var n1 int64
	n1, _ = strconv.ParseInt(s2, 10, 32)
	fmt.Println(n1)

	var n2 float64
	n2, _ = strconv.ParseFloat(s3, 64)
	fmt.Println(n2)

	var n3 uint64
	n3, _ = strconv.ParseUint(s4, 10, 64)
	fmt.Println(n3)
}
